export interface PermissionItemType {
  id: string
  permission_type: string
  permission_code: string
  permission_name: string
}

// 全量 - 权限映射
export const permission_map: PermissionItemType[] = [
  { id: '1', permission_type: '1', permission_code: 'home', permission_name: '首页' },
]

// 功能 - 权限映射
export function getActionPermissionList(): PermissionItemType[] {
  return permission_map.filter((i: PermissionItemType) => {
    return i.permission_type === '2'
  })
}

// 路由 - 权限映射
export function getRoutePermissionList(): PermissionItemType[] {
  return permission_map.filter((i: PermissionItemType) => {
    return i.permission_type === '1'
  })
}
